package cn.ligoo.part.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.ligoo.part.dao.RoleInfoDao;
import cn.ligoo.part.domain.RoleInfo;
import cn.ligoo.part.service.RoleInfoService;

/**
 * @author Jin,QingHua
 * @version 2012-07-17 16:46:31
 */
@Service
public class RoleInfoServiceImpl implements RoleInfoService {

	@Resource
	private RoleInfoDao roleInfoDao;

	@Override
	public Integer createRoleInfo(RoleInfo t) {
		this.roleInfoDao.insertEntity(t);
		return t.getId();
	}

	@Override
	public int modifyRoleInfo(RoleInfo t) {
		return this.roleInfoDao.updateEntity(t);
	}

	@Override
	public int removeRoleInfo(RoleInfo t) {
		return this.roleInfoDao.deleteEntity(t);
	}

	@Override
	public RoleInfo getRoleInfo(RoleInfo t) {
		return this.roleInfoDao.selectEntity(t);
	}

	@Override
	public Integer getRoleInfoCount(RoleInfo t) {
		return this.roleInfoDao.selectEntityCount(t);
	}

	@Override
	public List<RoleInfo> getRoleInfoList(RoleInfo t) {
		return this.roleInfoDao.selectEntityList(t);
	}

}
